package com.offcn.utils;

import java.util.List;

public class ListUtils {
    //List集合转字符串的方法
    public static String listToString(List<Object> list) {
        //定义一个字符串
        String str = "";
        //遍历List集合
        for (Object id : list) {
            str += "," + id;
        }
        //截取最开始的逗号
        str = str.substring(1);
        return str;
    }
}
